package com.yufei.infoExtractor.pfw.entity;

import java.util.ArrayList;

import java.util.List;

import javax.xml.bind.annotation.XmlElement;
import javax.xml.bind.annotation.XmlElementWrapper;
import javax.xml.bind.annotation.XmlRootElement;

import org.springframework.data.annotation.Id;
import org.springframework.data.mongodb.core.mapping.Document;

@XmlRootElement
public class Weibo extends Relatedlink {
	private String sign;

	public String getSign() {
		return sign;
	}

	public void setSign(String sign) {

		this.sign = sign;

	}

	public String getUserName() {
		return userName;
	}

	@XmlElement
	public void setUserName(String userName) {
		this.userName = userName;
	}

	public List<String> getContents() {
		return contents;
	}

	@XmlElementWrapper(name = "contents")
	@XmlElement(name = "content")
	public void setContents(List<String> contents) {
		this.contents = contents;
	}

	public void addContents(String content) {
		if (!contents.contains(content)) {
			contents.add(content);
		}

	}

	private String userName;
	private List<String> contents = new ArrayList();
	private String  selfDescription = null;
	private Integer followerNumber;
	private Integer followingNumber;
	private Integer contentsNumber;

	public String getSelfDescription() {
		return selfDescription;
	}

	@XmlElement
	public void setSelfDescription(String selfDescription) {
		this.selfDescription = selfDescription;
	}

	public Integer getFollowerNumber() {
		return followerNumber;
	}

	@XmlElement
	public void setFollowerNumber(Integer followerNumber) {
		this.followerNumber = followerNumber;
	}

	public Integer getFollowingNumber() {
		return followingNumber;
	}

	@XmlElement
	public void setFollowingNumber(Integer followingNumber) {
		this.followingNumber = followingNumber;
	}

	public Integer getContentsNumber() {
		return contentsNumber;
	}

	@XmlElement
	public void setContentsNumber(Integer contentsNumber) {
		this.contentsNumber = contentsNumber;
	}

}
